cmake_minimum_required (VERSION 2.8)
project (CS5721Graphics)

find_package(PNG REQUIRED)
if (PNG_FOUND)
  MESSAGE(STATUS "Found png: ${PNG_INCLUDE_DIR}, ${PNG_LIBRARY}")
  INCLUDE_DIRECTORIES(${PNG_INCLUDE_DIR})
endif (PNG_FOUND)

# --------------------------------------------------------------------
# SFML and OpenGL
# 
# --------------------------------------------------------------------
FIND_LIBRARY(SFML-SYSTEM_LIBRARY NAMES sfml-system )
FIND_LIBRARY(SFML-GRAPHICS_LIBRARY NAMES sfml-graphics )
FIND_LIBRARY(SFML-WINDOW_LIBRARY NAMES sfml-window )

FIND_PACKAGE(OpenGL REQUIRED)

# ----------------------------------------------------------
# Boost
#
# This section tests for Boost support on the system. Boost is
# required as it is used heavily with this code. Boost also allows the
# code to be nicely portable across Operating Systems.
# ----------------------------------------------------------
SET (Boost_MULTITHREADED TRUE)

# If you want to get more info on what the Find Boost macro is
# doing...  
# SET(Boost_DEBUG 1)

# Necessary to get Win32 version to work, plus, not a bad idea to link
# statically for our purposes.
SET(Boost_USE_STATIC_LIBS TRUE)

FIND_PACKAGE(Boost REQUIRED date_time program_options system thread unit_test_framework)
IF(${Boost_FOUND})
  INCLUDE_DIRECTORIES(${Boost_INCLUDE_DIR})
ENDIF()

include_directories(${CMAKE_SOURCE_DIR}/cs5721code/cs5721GraphicsLib/src)
include_directories(${CMAKE_SOURCE_DIR}/proj1/trunk/src)

add_subdirectory(cs5721code/cs5721GraphicsLib)

add_subdirectory(proj1/trunk)
